import { http } from "@/utils/http";

/** 获取所有轮播 */
export const getCarousel = (params?: object) => {
  return http.request<any>("get", "/carousel/getCarousel", { params });
};

/** 删除轮播 */
export const deleteCarousel = (params?: object) => {
  return http.request<any>("delete", "/carousel/deleteCarousel", {
    params
  });
};

/** 添加课轮播 */
export const addCarousel = (data?: object) => {
  return http.request<any>("post", "/carousel/addCarousel", { data });
};

/** 修改轮播 */
export const updateCarousel = (data?: object) => {
  return http.request<any>("put", "/carousel/updateCarousel", { data });
};
